package com.ctshk.app.order.scenic.controller;

import com.ctshk.common.dto.Result;
import com.ctshk.common.model.AppReq;
import com.ctshk.common.web.support.BaseController;
import com.ctshk.rpc.order.scenic.req.AirshowOrderCreateReq;
import com.ctshk.rpc.order.scenic.req.app.ScenicOrderAppPlaceOrderReq;
import com.ctshk.rpc.order.scenic.service.app.IAirshowAppOrderService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.apache.dubbo.config.annotation.DubboReference;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@Api(value = "景点门票订单服务-H5")
@RestController
@RequestMapping("/airshow")
public class AirshowOrderAppController extends BaseController {

    @DubboReference
    private IAirshowAppOrderService iAirshowAppOrderService;

    @PostMapping("/create-package-order")
    @ApiOperation(value = "套票下单", notes = "套票下单")
    public Result createPackageOrder(@RequestBody AirshowOrderCreateReq req){
        return iAirshowAppOrderService.createPackageOrder(req);
    }

    @PostMapping("/create-ticket-order")
    @ApiOperation(value = "门票下单", notes = "门票下单")
    public Result createTicketOrder(@RequestBody AirshowOrderCreateReq req){
        return iAirshowAppOrderService.createTicketOrder(req);
    }

}
